/*
 * $LastChangedDate: 2007-06-11 18:44:02 +0200 (Mon, 11 Jun 2007) $
 * $LastChangedRevision: 185 $
 * $LastChangedBy: david $
 */

#ifndef _LOG_H_
#define _LOG_H_

#include <string>
#include "FileMngr.h"
#include "Client.h"
#include "Server.h"

class FileMngr;

class Log
{
public:
	static const int INIT = 1;
	static const int CONNECTION = 2;
	static const int IO = 4;
	static const int LOCK = 8;
	static int loglevel;

	static bool isEnabled(int lvl);
	static void println(Client & cl, std::string s);
	static void println(Client & cl, std::string s, int logtype);
	static void println(Server & sv, std::string s);
	static void println(Server & sv, std::string s, int logtype);
	static void println(FileMngr & fm, std::string s);
	static void println(FileMngr & fm, std::string s, int logtype);

	Log();
	virtual ~Log();
};

#endif /* _LOG_H_ */

